Optimal. Leaf size=368 \[ -\frac{\left (a^2-b^2 x^2\right ) \left (f x \left (9 a^2 C f^2-b^2 \left (2 C e^2-4 f (3 A f+2 B e)\right )\right )+4 \left (4 a^2 f^2 (B f+2 C e)-b^2 e \left (C e^2-4 f (3 A f+B e)\right )\right )\right )}{24 b^4 f \sqrt{a+b x} \sqrt{a c-b c x}}+\frac{\sqrt{a^2 c-b^2 c x^2} \tan ^{-1}\left (\frac{b \sqrt{c} x}{\sqrt{a^2 c-b^2 c x^2}}\right ) \left (4 A \left (a^2 b^2 f^2+2 b^4 e^2\right )+a^2 \left (3 a^2 C f^2+4 b^2 e (2 B f+C e)\right )\right )}{8 b^5 \sqrt{c} \sqrt{a+b x} \sqrt{a c-b c x}}+\frac{\left (a^2-b^2 x^2\right ) (e+f x)^2 (C e-4 B f)}{12 b^2 f \sqrt{a+b x} \sqrt{a c-b c x}}-\frac{C \left (a^2-b^2 x^2\right ) (e+f x)^3}{4 b^2 f \sqrt{a+b x} \sqrt{a c-b c x}} \]
[Out]
_______________________________________________________________________________________
Rubi [A] time = 1.8231, antiderivative size = 369, normalized size of antiderivative = 1., number of steps used = 6, number of rules used = 6, integrand size = 40, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.15 \[ -\frac{\left (a^2-b^2 x^2\right ) \left (4 \left (4 a^2 f^2 (B f+2 C e)-\frac{1}{4} b^2 \left (4 C e^3-16 e f (3 A f+B e)\right )\right )+f x \left (9 a^2 C f^2-b^2 \left (2 C e^2-4 f (3 A f+2 B e)\right )\right )\right )}{24 b^4 f \sqrt{a+b x} \sqrt{a c-b c x}}+\frac{\left (a^2-b^2 x^2\right ) (e+f x)^2 (C e-4 B f)}{12 b^2 f \sqrt{a+b x} \sqrt{a c-b c x}}-\frac{C \left (a^2-b^2 x^2\right ) (e+f x)^3}{4 b^2 f \sqrt{a+b x} \sqrt{a c-b c x}}+\frac{\sqrt{a^2 c-b^2 c x^2} \tan ^{-1}\left (\frac{b \sqrt{c} x}{\sqrt{a^2 c-b^2 c x^2}}\right ) \left (3 a^4 C f^2+4 A \left (a^2 b^2 f^2+2 b^4 e^2\right )+4 a^2 b^2 e (2 B f+C e)\right )}{8 b^5 \sqrt{c} \sqrt{a+b x} \sqrt{a c-b c x}} \]
Antiderivative was successfully verified.
[In] Int[((e + f*x)^2*(A + B*x + C*x^2))/(Sqrt[a + b*x]*Sqrt[a*c - b*c*x]),x]
[Out]
_______________________________________________________________________________________
Rubi in Sympy [A] time = 170.581, size = 337, normalized size = 0.92 \[ - \frac{C \sqrt{a + b x} \left (e + f x\right )^{3} \sqrt{a c - b c x}}{4 b^{2} c f} - \frac{\sqrt{a + b x} \left (e + f x\right )^{2} \left (4 B f - C e\right ) \sqrt{a c - b c x}}{12 b^{2} c f} - \frac{\sqrt{a + b x} \sqrt{a c - b c x} \left (48 A b^{2} e f^{2} + 16 B a^{2} f^{3} + 16 B b^{2} e^{2} f + 32 C a^{2} e f^{2} - 4 C b^{2} e^{3} + f x \left (2 b^{2} e \left (4 B f - C e\right ) + f^{2} \left (12 A b^{2} + 9 C a^{2}\right )\right )\right )}{24 b^{4} c f} + \frac{\sqrt{a + b x} \sqrt{a c - b c x} \left (4 A a^{2} b^{2} f^{2} + 8 A b^{4} e^{2} + 8 B a^{2} b^{2} e f + 3 C a^{4} f^{2} + 4 C a^{2} b^{2} e^{2}\right ) \operatorname{atan}{\left (\frac{b \sqrt{c} x}{\sqrt{a^{2} c - b^{2} c x^{2}}} \right )}}{8 b^{5} \sqrt{c} \sqrt{a^{2} c - b^{2} c x^{2}}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In] rubi_integrate((f*x+e)**2*(C*x**2+B*x+A)/(b*x+a)**(1/2)/(-b*c*x+a*c)**(1/2),x)
[Out]
_______________________________________________________________________________________
Mathematica [A] time = 0.685117, size = 202, normalized size = 0.55 \[ \frac{3 \sqrt{a-b x} \tan ^{-1}\left (\frac{b x}{\sqrt{a-b x} \sqrt{a+b x}}\right ) \left (3 a^4 C f^2+4 A \left (a^2 b^2 f^2+2 b^4 e^2\right )+4 a^2 b^2 e (2 B f+C e)\right )-b (a-b x) \sqrt{a+b x} \left (a^2 f (16 B f+32 C e+9 C f x)+2 b^2 \left (6 A f (4 e+f x)+4 B \left (3 e^2+3 e f x+f^2 x^2\right )+C x \left (6 e^2+8 e f x+3 f^2 x^2\right )\right )\right )}{24 b^5 \sqrt{c (a-b x)}} \]
Antiderivative was successfully verified.
[In] Integrate[((e + f*x)^2*(A + B*x + C*x^2))/(Sqrt[a + b*x]*Sqrt[a*c - b*c*x]),x]
[Out]
_______________________________________________________________________________________
Maple [A] time = 0.036, size = 635, normalized size = 1.7 \[{\frac{1}{24\,{b}^{4}c}\sqrt{bx+a}\sqrt{-c \left ( bx-a \right ) } \left ( -6\,C{x}^{3}{b}^{2}{f}^{2}\sqrt{{b}^{2}c}\sqrt{-c \left ({b}^{2}{x}^{2}-{a}^{2} \right ) }+12\,{f}^{2}Ac{a}^{2}\arctan \left ({\frac{\sqrt{{b}^{2}c}x}{\sqrt{-c \left ({b}^{2}{x}^{2}-{a}^{2} \right ) }}} \right ){b}^{2}+24\,c\arctan \left ({\frac{\sqrt{{b}^{2}c}x}{\sqrt{-c \left ({b}^{2}{x}^{2}-{a}^{2} \right ) }}} \right ) A{e}^{2}{b}^{4}+24\,Bfec{a}^{2}\arctan \left ({\frac{\sqrt{{b}^{2}c}x}{\sqrt{-c \left ({b}^{2}{x}^{2}-{a}^{2} \right ) }}} \right ){b}^{2}-8\,B{x}^{2}{b}^{2}{f}^{2}\sqrt{{b}^{2}c}\sqrt{-c \left ({b}^{2}{x}^{2}-{a}^{2} \right ) }+9\,{a}^{4}C{f}^{2}c\arctan \left ({\frac{\sqrt{{b}^{2}c}x}{\sqrt{-c \left ({b}^{2}{x}^{2}-{a}^{2} \right ) }}} \right ) +12\,{e}^{2}Cc{a}^{2}\arctan \left ({\frac{\sqrt{{b}^{2}c}x}{\sqrt{-c \left ({b}^{2}{x}^{2}-{a}^{2} \right ) }}} \right ){b}^{2}-16\,C{x}^{2}{b}^{2}ef\sqrt{{b}^{2}c}\sqrt{-c \left ({b}^{2}{x}^{2}-{a}^{2} \right ) }-12\,{f}^{2}Ax\sqrt{-c \left ({b}^{2}{x}^{2}-{a}^{2} \right ) }{b}^{2}\sqrt{{b}^{2}c}-24\,Bfex\sqrt{-c \left ({b}^{2}{x}^{2}-{a}^{2} \right ) }{b}^{2}\sqrt{{b}^{2}c}-9\,{a}^{2}C{f}^{2}x\sqrt{-c \left ({b}^{2}{x}^{2}-{a}^{2} \right ) }\sqrt{{b}^{2}c}-12\,{e}^{2}Cx\sqrt{-c \left ({b}^{2}{x}^{2}-{a}^{2} \right ) }{b}^{2}\sqrt{{b}^{2}c}-48\,\sqrt{-c \left ({b}^{2}{x}^{2}-{a}^{2} \right ) }Aef{b}^{2}\sqrt{{b}^{2}c}-16\,{a}^{2}\sqrt{-c \left ({b}^{2}{x}^{2}-{a}^{2} \right ) }B{f}^{2}\sqrt{{b}^{2}c}-24\,\sqrt{-c \left ({b}^{2}{x}^{2}-{a}^{2} \right ) }B{e}^{2}{b}^{2}\sqrt{{b}^{2}c}-32\,{a}^{2}\sqrt{-c \left ({b}^{2}{x}^{2}-{a}^{2} \right ) }Cef\sqrt{{b}^{2}c} \right ){\frac{1}{\sqrt{-c \left ({b}^{2}{x}^{2}-{a}^{2} \right ) }}}{\frac{1}{\sqrt{{b}^{2}c}}}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In] int((f*x+e)^2*(C*x^2+B*x+A)/(b*x+a)^(1/2)/(-b*c*x+a*c)^(1/2),x)
[Out]
_______________________________________________________________________________________
Maxima [F] time = 0., size = 0, normalized size = 0. \[ \text{Exception raised: ValueError} \]
Verification of antiderivative is not currently implemented for this CAS.
[In] integrate((C*x^2 + B*x + A)*(f*x + e)^2/(sqrt(-b*c*x + a*c)*sqrt(b*x + a)),x, algorithm="maxima")
[Out]
_______________________________________________________________________________________
Fricas [A] time = 0.271191, size = 1, normalized size = 0. \[ \left [-\frac{2 \,{\left (6 \, C b^{3} f^{2} x^{3} + 24 \, B b^{3} e^{2} + 16 \, B a^{2} b f^{2} + 16 \,{\left (2 \, C a^{2} b + 3 \, A b^{3}\right )} e f + 8 \,{\left (2 \, C b^{3} e f + B b^{3} f^{2}\right )} x^{2} + 3 \,{\left (4 \, C b^{3} e^{2} + 8 \, B b^{3} e f +{\left (3 \, C a^{2} b + 4 \, A b^{3}\right )} f^{2}\right )} x\right )} \sqrt{-b c x + a c} \sqrt{b x + a} \sqrt{-c} - 3 \,{\left (8 \, B a^{2} b^{2} c e f + 4 \,{\left (C a^{2} b^{2} + 2 \, A b^{4}\right )} c e^{2} +{\left (3 \, C a^{4} + 4 \, A a^{2} b^{2}\right )} c f^{2}\right )} \log \left (2 \, \sqrt{-b c x + a c} \sqrt{b x + a} b x +{\left (2 \, b^{2} x^{2} - a^{2}\right )} \sqrt{-c}\right )}{48 \, b^{5} \sqrt{-c} c}, -\frac{{\left (6 \, C b^{3} f^{2} x^{3} + 24 \, B b^{3} e^{2} + 16 \, B a^{2} b f^{2} + 16 \,{\left (2 \, C a^{2} b + 3 \, A b^{3}\right )} e f + 8 \,{\left (2 \, C b^{3} e f + B b^{3} f^{2}\right )} x^{2} + 3 \,{\left (4 \, C b^{3} e^{2} + 8 \, B b^{3} e f +{\left (3 \, C a^{2} b + 4 \, A b^{3}\right )} f^{2}\right )} x\right )} \sqrt{-b c x + a c} \sqrt{b x + a} \sqrt{c} - 3 \,{\left (8 \, B a^{2} b^{2} c e f + 4 \,{\left (C a^{2} b^{2} + 2 \, A b^{4}\right )} c e^{2} +{\left (3 \, C a^{4} + 4 \, A a^{2} b^{2}\right )} c f^{2}\right )} \arctan \left (\frac{b \sqrt{c} x}{\sqrt{-b c x + a c} \sqrt{b x + a}}\right )}{24 \, b^{5} c^{\frac{3}{2}}}\right ] \]
Verification of antiderivative is not currently implemented for this CAS.
[In] integrate((C*x^2 + B*x + A)*(f*x + e)^2/(sqrt(-b*c*x + a*c)*sqrt(b*x + a)),x, algorithm="fricas")
[Out]
_______________________________________________________________________________________
Sympy [F(-1)] time = 0., size = 0, normalized size = 0. \[ \text{Timed out} \]
Verification of antiderivative is not currently implemented for this CAS.
[In] integrate((f*x+e)**2*(C*x**2+B*x+A)/(b*x+a)**(1/2)/(-b*c*x+a*c)**(1/2),x)
[Out]
_______________________________________________________________________________________
GIAC/XCAS [F(-1)] time = 0., size = 0, normalized size = 0. \[ \text{Timed out} \]
Verification of antiderivative is not currently implemented for this CAS.
[In] integrate((C*x^2 + B*x + A)*(f*x + e)^2/(sqrt(-b*c*x + a*c)*sqrt(b*x + a)),x, algorithm="giac")
[Out]